import { MenuType } from "../constant/menu-type";

/**
 *  模块菜单
 */
export class menu {
    // id标识
    id: number;

    // 模块标识
    name: string;

    // 模块显示名称
    displayName: string;

    // 模块路径
    path: string;

    // 菜单类型
    type: MenuType = MenuType.MENU;

    /**
     *  对应的页面地址
     */
    page: string;

    // 图标
    icon?: string;

    // 子模块
    children?: Array<menu>;

    constructor(id: number, name: string, displayName: string, path: string, page: string) {
        this.id = id;
        this.name = name;
        this.displayName = displayName;
        this.path = path;
        this.page = page;
    }
}
